<?php
/**
 * TOP API: taobao.alitrip.travel.item.element.manage request
 * 
 * @author auto create
 * @since 1.0, 2018.07.25
 */
class AlitripTravelItemElementManageRequest
{
	/** 
	 * 元素所在城市，景点、酒店在新增时必填
	 **/
	private $city;
	
	/** 
	 * 当新增“交通接驳、餐饮、特色活动、其他”资源类型时 必填
	 **/
	private $desc;
	
	/** 
	 * 资源元素类型，新增时必填：1-景点，2-酒店，5-交通接驳，6-WIFI库；8-餐饮，9-签证库，11-特色活动，999-其他
	 **/
	private $elementType;
	
	/** 
	 * 元素名称，新增时必填； 注意：Wifi库的使用地和签证库所在国家均适用这个字段
	 **/
	private $name;
	
	/** 
	 * 必填，操作类型：1-新增，2-修改，3-删除。。特别注意：删除 为逻辑删除，即该outer_id所对应的元素还存在但是会置为无效状态，重新编辑修改即可恢复为有效状态。因此该id一旦使用将不可重复
	 **/
	private $operation;
	
	/** 
	 * 必填，元素的外部商家编码，必须唯一。编辑、删除时将根据该编码找到对应元素。
	 **/
	private $outerId;
	
	/** 
	 * 元素的子类型，新增时必填。景点指门票类型，酒店指房型信息，交通接驳（接送机、接驳车、租车、船票、其他）选其一，餐饮（早餐、晚餐、午餐、下午茶及其他）选其一；签证（旅游签证、商务签证、工作签证、留学签证、探亲访友签证、入台证、其他）
	 **/
	private $type;
	
	private $apiParas = array();
	
	public function setCity($city)
	{
		$this->city = $city;
		$this->apiParas["city"] = $city;
	}

	public function getCity()
	{
		return $this->city;
	}

	public function setDesc($desc)
	{
		$this->desc = $desc;
		$this->apiParas["desc"] = $desc;
	}

	public function getDesc()
	{
		return $this->desc;
	}

	public function setElementType($elementType)
	{
		$this->elementType = $elementType;
		$this->apiParas["element_type"] = $elementType;
	}

	public function getElementType()
	{
		return $this->elementType;
	}

	public function setName($name)
	{
		$this->name = $name;
		$this->apiParas["name"] = $name;
	}

	public function getName()
	{
		return $this->name;
	}

	public function setOperation($operation)
	{
		$this->operation = $operation;
		$this->apiParas["operation"] = $operation;
	}

	public function getOperation()
	{
		return $this->operation;
	}

	public function setOuterId($outerId)
	{
		$this->outerId = $outerId;
		$this->apiParas["outer_id"] = $outerId;
	}

	public function getOuterId()
	{
		return $this->outerId;
	}

	public function setType($type)
	{
		$this->type = $type;
		$this->apiParas["type"] = $type;
	}

	public function getType()
	{
		return $this->type;
	}

	public function getApiMethodName()
	{
		return "taobao.alitrip.travel.item.element.manage";
	}
	
	public function getApiParas()
	{
		return $this->apiParas;
	}
	
	public function check()
	{
		
		RequestCheckUtil::checkNotNull($this->operation,"operation");
		RequestCheckUtil::checkNotNull($this->outerId,"outerId");
	}
	
	public function putOtherTextParam($key, $value) {
		$this->apiParas[$key] = $value;
		$this->$key = $value;
	}
}
